# Maintainer: Felix Yan <felixonmars@archlinux.org>
# Contributor: Bruce Zhang

pkgname=vkd3d
pkgver=1.6
pkgrel=1
pkgdesc='Direct3D 12 to Vulkan translation library By WineHQ'
arch=('loong64' 'x86_64')
url='https://wiki.winehq.org/Vkd3d'
license=('LGPL')
depends=('spirv-tools' 'vulkan-icd-loader')
makedepends=('spirv-headers' 'vulkan-headers' 'xcb-util-keysyms' 'xorgproto')
source=("https://dl.winehq.org/vkd3d/source/vkd3d-$pkgver.tar.xz")
sha512sums=('0f640c1b139f5ccce8e6d1986d1439c2b0d14e7ac533216d2408dbeee07172eee51549311db22464c2ae89070ca15191aaffd967749676586984561ce1d4b38f')

prepare() {
  cd vkd3d-$pkgver
  ./configure --prefix=/usr --with-spirv-tools
}

build() {
  cd vkd3d-$pkgver
  make
}

package() {
  cd vkd3d-$pkgver
  make DESTDIR="$pkgdir" install
}
